<template>
	<view class="content fofa">
		<tabnav title="新用户指南" :col="back"></tabnav>
		<view class="beijingTop"></view>
		<view class="wid100 dis disJuC" style="margin-top: -200rpx;">
			<image :src="aurl+icon_list.zizhan" style="height: 279rpx;" class="wid87"></image>
		</view>
		<view style="height: 10rpx;"></view>
		<view class="wid87 mar dis disAl flwa disJuB">
			<block v-for="(item,index) in list" :key="index">
				<view class="bacFFF borRad10 dis disAl disJuC mar-top20 box1" 
				@click="tiaozhuan('/pages/common/richtext?xq=0&id='+item.id)" 
				style="width: 48%;height: 219rpx;">
					<view>
						<view class="textCen foSi25 fowe800">{{item.title}}</view>
						<view class="wid100 dis disJuC mar-top20">
							<image :src="url+item.coverimg" style="width: 178rpx;height: 118rpx;"></image>
						</view>
					</view>
				</view>
			</block>
		</view>
	</view>
</template>

<script>
	import tabnav from "../common/tabnav/tabnav.vue"
	export default {
		components: {
			tabnav,
		},
		data() {
			return {
				aurl:this.global.url,
				back: uni.getStorageSync('back'),
				list: [],
				url: this.global.url,
				icon_list:{
					zizhan:'/addon/qianyu_dzq/wechatimg/zizhan.png'
				}
			}
		},
		onLoad() {
			this.appletList()
		},
		methods: {
			appletList(){
				var that = this
				uni.showLoading({
					title:'加载中...'
				})
				uni.request({
					url: that.global.url+'api/qianyu_dzq/applet_guide_list',
					method: 'POST',
					header:{'site-id':that.global.site_id},
					data: {},
					success(res) {
					    let result = res.data
						console.log(result);
					    if(result.code == 1){
					       that.list = result.data
					    }else{
					        uni.showToast({
					            title: result.msg,
					            icon:'none',
								duration: 2000
					        })
					    }
					},
					complete() {
						uni.hideLoading()
					}
				})
			},
			tiaozhuan(url){
				uni.navigateTo({
					url: url
				});
			},
		}
	}
</script>

<style>
	.content {
		min-height: 100vh;
		background-color: #F4F3F3;
	}
	.xia{
		height: 1rpx;
		background: #BFBFBF;
	}
	.beijingTop{
		background-color: #035DFF;
		border-bottom-left-radius: 50%;
		border-bottom-right-radius: 50%;
		height: 263rpx;
	}
</style>
